stable-diffusion-webui And Dealing With Multiple GPUs

This article deals with AUTOMATIC1111/stable-diffusion-webui on Windows 11. Linux would have slightly different steps - more specifically around webui-user.bat/webui-user.sh - but they're still both pretty similar and use the same environment variable names, just different scripting languages.

If you have multiple GPUs, you can use the following line to choose between each of them:

set CUDA_VISIBLE_DEVICES=0

Note that 0 is for GPU number 1, and 1 and for GPU number 2. If you have more, then the number would continue...

You can find out which GPU is assigned to which number by opening Task Manager -> Performance, where GPU 0 would have the value 0, and GPU 1 would have the value 1.


Check out these articles...
2023-07-08 09:05:45 SAP PO Release Checklist
2023-08-07 21:13:39 Mounting libvirtd Over SSH
2023-08-20 20:14:20 Stop VSCode From Ignoring Linux Remaps
2024-02-22 00:05:20 VMware Workstation Pro Keys
2024-05-01 19:03:49 What is AvistaZ?